# 包含头文件目录
include_directories(
    libAACdec/include
    libAACenc/include
    libPCMutils/include
    libFDK/include
    libSYS/include
    libMpegTPDec/include
    libMpegTPEnc/include
    libSBRdec/include
    libSBRenc/include
)

aux_source_directory(${CMAKE_CURRENT_SOURCE_DIR}/libAACdec/src/ LIB_AAC_SRC)

add_library(AAC SHARED ${LIB_AAC_SRC})

target_compile_definitions(AAC PRIVATE BUILD_FOR_ANDROID)
target_compile_options(AAC PRIVATE
    -Wno-error=date-time
    -Wno-error=int-conversion
    -Wno-sequence-point
    -Wno-extra
    -Wno-warnings
    -Wno-constant-logical-operand
    -Wno-self-assign
)

target_link_options(AAC PRIVATE -Wl,--unresolved-symbols=ignore-all)

# 如需链接 log 库，取消下行注释
# target_link_libraries(AAC log)